package javat.util;

import static net.ftng.commons.lang.utils.PrintUtils.println;
import static org.junit.Assert.assertEquals;
import net.ftng.commons.lang.utils.MathUtils;

import org.junit.Test;

public class CharTest {

    @Test
    public void UpperCaseAlphabetic() {

        char c = (char) MathUtils.randomInt(65, 90);
        println(c);
    }

    @Test
    public void LowerCaseAlphabetic() {

        char c = (char) MathUtils.randomInt(97, 122);
        println(c);
    }

    @Test
    public void integerToChar() {

        char charA = (char) 64 + 1;
        assertEquals('A', charA);
    }

    @Test
    public void charToInteger() {

        int charA = 'A';
        assertEquals(65, charA);
    }
}
